package com.jackstraw.jack_base.rules.entity.po;

import com.jackstraw.jack_base.datasource.mybatis.base.entity.po.PoExample;
import com.jackstraw.jack_base.util.JsonUtil;
import com.jackstraw.jack_base.util.ObjectUtil;

import java.util.ArrayList;
import java.util.List;
import java.util.Map;
import java.util.Date;


/**
 * 规则表	实体层PoExample
 *
 * @author zhaozhao 945514650@qq.com
 * @since version:1.0 generatorDate:2022-12-04 14:28:29
 */
public class RulePoExample extends PoExample<RulePoExample.Criteria, RulePo> {

	public RulePoExample() {
		super();
	}

	@Override
	public void addKey(Map<String, Object> params) {
		RulePo po = JsonUtil.mapToBean(params, this.poClass);
		if (ObjectUtil.ObjectUtilByLang3.isNotEmpty(po)) {
			if (ObjectUtil.ObjectUtilByLang3.isNotEmpty(po.getRuleId())) {
				this.createCriteria().andRuleIdEqualTo(po.getRuleId());
			}
 		}
	}

	@Override
	protected Criteria createCriteriaInternal() {
		return new Criteria();
	}


	protected abstract static class GeneratedCriteria {
		protected List<Criterion> criteria;

		protected GeneratedCriteria() {
			super();
			criteria = new ArrayList<Criterion>();
		}

		public boolean isValid() {
			return criteria.size() > 0;
		}

		public List<Criterion> getAllCriteria() {
			return criteria;
		}

		public List<Criterion> getCriteria() {
			return criteria;
		}

		protected void addCriterion(String condition) {
			if (condition == null) {
				throw new RuntimeException("Value for condition cannot be null");
			}
			criteria.add(new Criterion(condition));
		}

		protected void addCriterion(String condition, Object value, String property) {
			if (value == null) {
				throw new RuntimeException("Value for " + property + " cannot be null");
			}
			criteria.add(new Criterion(condition, value));
		}

		protected void addCriterion(String condition, Object value1, Object value2, String property) {
			if (value1 == null || value2 == null) {
				throw new RuntimeException("Between values for " + property + " cannot be null");
			}
			criteria.add(new Criterion(condition, value1, value2));
		}

		public Criteria andRuleIdIsNull() {
			addCriterion("rule_id is null");
			return (Criteria) this;
		}

		public Criteria andRuleIdIsNotNull() {
			addCriterion("rule_id is not null");
			return (Criteria) this;
		}

		public Criteria andRuleIdEqualTo(Long value) {
			addCriterion("rule_id =", value, "ruleId");
			return (Criteria) this;
		}

		public Criteria andRuleIdNotEqualTo(Long value) {
			addCriterion("rule_id <>", value, "ruleId");
			return (Criteria) this;
		}

		public Criteria andRuleIdGreaterThan(Long value) {
			addCriterion("rule_id >", value, "ruleId");
			return (Criteria) this;
		}

		public Criteria andRuleIdGreaterThanOrEqualTo(Long value) {
			addCriterion("rule_id >=", value, "ruleId");
			return (Criteria) this;
		}

		public Criteria andRuleIdLessThan(Long value) {
			addCriterion("rule_id <", value, "ruleId");
			return (Criteria) this;
		}

		public Criteria andRuleIdLessThanOrEqualTo(Long value) {
			addCriterion("rule_id <=", value, "ruleId");
			return (Criteria) this;
		}

		public Criteria andRuleIdIn(List<Long> values) {
			addCriterion("rule_id in", values, "ruleId");
			return (Criteria) this;
		}

		public Criteria andRuleIdNotIn(List<Long> values) {
			addCriterion("rule_id not in", values, "ruleId");
			return (Criteria) this;
		}

		public Criteria andRuleIdBetween(Long value1, Long value2) {
			addCriterion("rule_id between", value1, value2, "ruleId");
			return (Criteria) this;
		}

		public Criteria andRuleIdNotBetween(Long value1, Long value2) {
			addCriterion("rule_id not between", value1, value2, "ruleId");
			return (Criteria) this;
		}


		public Criteria andRuleDescIsNull() {
			addCriterion("rule_desc is null");
			return (Criteria) this;
		}

		public Criteria andRuleDescIsNotNull() {
			addCriterion("rule_desc is not null");
			return (Criteria) this;
		}

		public Criteria andRuleDescEqualTo(String value) {
			addCriterion("rule_desc =", value, "ruleDesc");
			return (Criteria) this;
		}

		public Criteria andRuleDescNotEqualTo(String value) {
			addCriterion("rule_desc <>", value, "ruleDesc");
			return (Criteria) this;
		}

		public Criteria andRuleDescGreaterThan(String value) {
			addCriterion("rule_desc >", value, "ruleDesc");
			return (Criteria) this;
		}

		public Criteria andRuleDescGreaterThanOrEqualTo(String value) {
			addCriterion("rule_desc >=", value, "ruleDesc");
			return (Criteria) this;
		}

		public Criteria andRuleDescLessThan(String value) {
			addCriterion("rule_desc <", value, "ruleDesc");
			return (Criteria) this;
		}

		public Criteria andRuleDescLessThanOrEqualTo(String value) {
			addCriterion("rule_desc <=", value, "ruleDesc");
			return (Criteria) this;
		}

		public Criteria andRuleDescIn(List<String> values) {
			addCriterion("rule_desc in", values, "ruleDesc");
			return (Criteria) this;
		}

		public Criteria andRuleDescNotIn(List<String> values) {
			addCriterion("rule_desc not in", values, "ruleDesc");
			return (Criteria) this;
		}

		public Criteria andRuleDescBetween(String value1, String value2) {
			addCriterion("rule_desc between", value1, value2, "ruleDesc");
			return (Criteria) this;
		}

		public Criteria andRuleDescNotBetween(String value1, String value2) {
			addCriterion("rule_desc not between", value1, value2, "ruleDesc");
			return (Criteria) this;
		}

		public Criteria andRuleDescLike(String value) {
			addCriterion("rule_desc like", value, "ruleDesc");
			return (Criteria) this;
		}

		public Criteria andRuleDescNotLike(String value) {
			addCriterion("rule_desc not like", value, "ruleDesc");
			return (Criteria) this;
		}

		public Criteria andRuleDescLikeInsensitive(String value) {
			addCriterion("upper(rule_desc) like", value.toUpperCase(), "ruleDesc");
			return (Criteria) this;
		}


		public Criteria andRuleTypeIsNull() {
			addCriterion("rule_type is null");
			return (Criteria) this;
		}

		public Criteria andRuleTypeIsNotNull() {
			addCriterion("rule_type is not null");
			return (Criteria) this;
		}

		public Criteria andRuleTypeEqualTo(Integer value) {
			addCriterion("rule_type =", value, "ruleType");
			return (Criteria) this;
		}

		public Criteria andRuleTypeNotEqualTo(Integer value) {
			addCriterion("rule_type <>", value, "ruleType");
			return (Criteria) this;
		}

		public Criteria andRuleTypeGreaterThan(Integer value) {
			addCriterion("rule_type >", value, "ruleType");
			return (Criteria) this;
		}

		public Criteria andRuleTypeGreaterThanOrEqualTo(Integer value) {
			addCriterion("rule_type >=", value, "ruleType");
			return (Criteria) this;
		}

		public Criteria andRuleTypeLessThan(Integer value) {
			addCriterion("rule_type <", value, "ruleType");
			return (Criteria) this;
		}

		public Criteria andRuleTypeLessThanOrEqualTo(Integer value) {
			addCriterion("rule_type <=", value, "ruleType");
			return (Criteria) this;
		}

		public Criteria andRuleTypeIn(List<Integer> values) {
			addCriterion("rule_type in", values, "ruleType");
			return (Criteria) this;
		}

		public Criteria andRuleTypeNotIn(List<Integer> values) {
			addCriterion("rule_type not in", values, "ruleType");
			return (Criteria) this;
		}

		public Criteria andRuleTypeBetween(Integer value1, Integer value2) {
			addCriterion("rule_type between", value1, value2, "ruleType");
			return (Criteria) this;
		}

		public Criteria andRuleTypeNotBetween(Integer value1, Integer value2) {
			addCriterion("rule_type not between", value1, value2, "ruleType");
			return (Criteria) this;
		}


		public Criteria andRuleTextIsNull() {
			addCriterion("rule_text is null");
			return (Criteria) this;
		}

		public Criteria andRuleTextIsNotNull() {
			addCriterion("rule_text is not null");
			return (Criteria) this;
		}

		public Criteria andRuleTextEqualTo(String value) {
			addCriterion("rule_text =", value, "ruleText");
			return (Criteria) this;
		}

		public Criteria andRuleTextNotEqualTo(String value) {
			addCriterion("rule_text <>", value, "ruleText");
			return (Criteria) this;
		}

		public Criteria andRuleTextGreaterThan(String value) {
			addCriterion("rule_text >", value, "ruleText");
			return (Criteria) this;
		}

		public Criteria andRuleTextGreaterThanOrEqualTo(String value) {
			addCriterion("rule_text >=", value, "ruleText");
			return (Criteria) this;
		}

		public Criteria andRuleTextLessThan(String value) {
			addCriterion("rule_text <", value, "ruleText");
			return (Criteria) this;
		}

		public Criteria andRuleTextLessThanOrEqualTo(String value) {
			addCriterion("rule_text <=", value, "ruleText");
			return (Criteria) this;
		}

		public Criteria andRuleTextIn(List<String> values) {
			addCriterion("rule_text in", values, "ruleText");
			return (Criteria) this;
		}

		public Criteria andRuleTextNotIn(List<String> values) {
			addCriterion("rule_text not in", values, "ruleText");
			return (Criteria) this;
		}

		public Criteria andRuleTextBetween(String value1, String value2) {
			addCriterion("rule_text between", value1, value2, "ruleText");
			return (Criteria) this;
		}

		public Criteria andRuleTextNotBetween(String value1, String value2) {
			addCriterion("rule_text not between", value1, value2, "ruleText");
			return (Criteria) this;
		}

		public Criteria andRuleTextLike(String value) {
			addCriterion("rule_text like", value, "ruleText");
			return (Criteria) this;
		}

		public Criteria andRuleTextNotLike(String value) {
			addCriterion("rule_text not like", value, "ruleText");
			return (Criteria) this;
		}

		public Criteria andRuleTextLikeInsensitive(String value) {
			addCriterion("upper(rule_text) like", value.toUpperCase(), "ruleText");
			return (Criteria) this;
		}


		public Criteria andVersionIsNull() {
			addCriterion("version is null");
			return (Criteria) this;
		}

		public Criteria andVersionIsNotNull() {
			addCriterion("version is not null");
			return (Criteria) this;
		}

		public Criteria andVersionEqualTo(Integer value) {
			addCriterion("version =", value, "version");
			return (Criteria) this;
		}

		public Criteria andVersionNotEqualTo(Integer value) {
			addCriterion("version <>", value, "version");
			return (Criteria) this;
		}

		public Criteria andVersionGreaterThan(Integer value) {
			addCriterion("version >", value, "version");
			return (Criteria) this;
		}

		public Criteria andVersionGreaterThanOrEqualTo(Integer value) {
			addCriterion("version >=", value, "version");
			return (Criteria) this;
		}

		public Criteria andVersionLessThan(Integer value) {
			addCriterion("version <", value, "version");
			return (Criteria) this;
		}

		public Criteria andVersionLessThanOrEqualTo(Integer value) {
			addCriterion("version <=", value, "version");
			return (Criteria) this;
		}

		public Criteria andVersionIn(List<Integer> values) {
			addCriterion("version in", values, "version");
			return (Criteria) this;
		}

		public Criteria andVersionNotIn(List<Integer> values) {
			addCriterion("version not in", values, "version");
			return (Criteria) this;
		}

		public Criteria andVersionBetween(Integer value1, Integer value2) {
			addCriterion("version between", value1, value2, "version");
			return (Criteria) this;
		}

		public Criteria andVersionNotBetween(Integer value1, Integer value2) {
			addCriterion("version not between", value1, value2, "version");
			return (Criteria) this;
		}


		public Criteria andIsValidIsNull() {
			addCriterion("is_valid is null");
			return (Criteria) this;
		}

		public Criteria andIsValidIsNotNull() {
			addCriterion("is_valid is not null");
			return (Criteria) this;
		}

		public Criteria andIsValidEqualTo(Integer value) {
			addCriterion("is_valid =", value, "isValid");
			return (Criteria) this;
		}

		public Criteria andIsValidNotEqualTo(Integer value) {
			addCriterion("is_valid <>", value, "isValid");
			return (Criteria) this;
		}

		public Criteria andIsValidGreaterThan(Integer value) {
			addCriterion("is_valid >", value, "isValid");
			return (Criteria) this;
		}

		public Criteria andIsValidGreaterThanOrEqualTo(Integer value) {
			addCriterion("is_valid >=", value, "isValid");
			return (Criteria) this;
		}

		public Criteria andIsValidLessThan(Integer value) {
			addCriterion("is_valid <", value, "isValid");
			return (Criteria) this;
		}

		public Criteria andIsValidLessThanOrEqualTo(Integer value) {
			addCriterion("is_valid <=", value, "isValid");
			return (Criteria) this;
		}

		public Criteria andIsValidIn(List<Integer> values) {
			addCriterion("is_valid in", values, "isValid");
			return (Criteria) this;
		}

		public Criteria andIsValidNotIn(List<Integer> values) {
			addCriterion("is_valid not in", values, "isValid");
			return (Criteria) this;
		}

		public Criteria andIsValidBetween(Integer value1, Integer value2) {
			addCriterion("is_valid between", value1, value2, "isValid");
			return (Criteria) this;
		}

		public Criteria andIsValidNotBetween(Integer value1, Integer value2) {
			addCriterion("is_valid not between", value1, value2, "isValid");
			return (Criteria) this;
		}


		public Criteria andCreateTimeIsNull() {
			addCriterion("create_time is null");
			return (Criteria) this;
		}

		public Criteria andCreateTimeIsNotNull() {
			addCriterion("create_time is not null");
			return (Criteria) this;
		}

		public Criteria andCreateTimeEqualTo(Date value) {
			addCriterion("create_time =", value, "createTime");
			return (Criteria) this;
		}

		public Criteria andCreateTimeNotEqualTo(Date value) {
			addCriterion("create_time <>", value, "createTime");
			return (Criteria) this;
		}

		public Criteria andCreateTimeGreaterThan(Date value) {
			addCriterion("create_time >", value, "createTime");
			return (Criteria) this;
		}

		public Criteria andCreateTimeGreaterThanOrEqualTo(Date value) {
			addCriterion("create_time >=", value, "createTime");
			return (Criteria) this;
		}

		public Criteria andCreateTimeLessThan(Date value) {
			addCriterion("create_time <", value, "createTime");
			return (Criteria) this;
		}

		public Criteria andCreateTimeLessThanOrEqualTo(Date value) {
			addCriterion("create_time <=", value, "createTime");
			return (Criteria) this;
		}

		public Criteria andCreateTimeIn(List<Date> values) {
			addCriterion("create_time in", values, "createTime");
			return (Criteria) this;
		}

		public Criteria andCreateTimeNotIn(List<Date> values) {
			addCriterion("create_time not in", values, "createTime");
			return (Criteria) this;
		}

		public Criteria andCreateTimeBetween(Date value1, Date value2) {
			addCriterion("create_time between", value1, value2, "createTime");
			return (Criteria) this;
		}

		public Criteria andCreateTimeNotBetween(Date value1, Date value2) {
			addCriterion("create_time not between", value1, value2, "createTime");
			return (Criteria) this;
		}


		public Criteria andUpdateTimeIsNull() {
			addCriterion("update_time is null");
			return (Criteria) this;
		}

		public Criteria andUpdateTimeIsNotNull() {
			addCriterion("update_time is not null");
			return (Criteria) this;
		}

		public Criteria andUpdateTimeEqualTo(Date value) {
			addCriterion("update_time =", value, "updateTime");
			return (Criteria) this;
		}

		public Criteria andUpdateTimeNotEqualTo(Date value) {
			addCriterion("update_time <>", value, "updateTime");
			return (Criteria) this;
		}

		public Criteria andUpdateTimeGreaterThan(Date value) {
			addCriterion("update_time >", value, "updateTime");
			return (Criteria) this;
		}

		public Criteria andUpdateTimeGreaterThanOrEqualTo(Date value) {
			addCriterion("update_time >=", value, "updateTime");
			return (Criteria) this;
		}

		public Criteria andUpdateTimeLessThan(Date value) {
			addCriterion("update_time <", value, "updateTime");
			return (Criteria) this;
		}

		public Criteria andUpdateTimeLessThanOrEqualTo(Date value) {
			addCriterion("update_time <=", value, "updateTime");
			return (Criteria) this;
		}

		public Criteria andUpdateTimeIn(List<Date> values) {
			addCriterion("update_time in", values, "updateTime");
			return (Criteria) this;
		}

		public Criteria andUpdateTimeNotIn(List<Date> values) {
			addCriterion("update_time not in", values, "updateTime");
			return (Criteria) this;
		}

		public Criteria andUpdateTimeBetween(Date value1, Date value2) {
			addCriterion("update_time between", value1, value2, "updateTime");
			return (Criteria) this;
		}

		public Criteria andUpdateTimeNotBetween(Date value1, Date value2) {
			addCriterion("update_time not between", value1, value2, "updateTime");
			return (Criteria) this;
		}

	}

	public static class Criteria extends GeneratedCriteria {

		protected Criteria() {
			super();
		}
	}
}